package com.goodving.guli.utility;

import android.annotation.SuppressLint;

import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;

/**
 * Created by Administrator on 2015-11-17.
 */
public class C1466h {
    @SuppressLint({"SimpleDateFormat"})
    public static String m11947a() {
        return C1466h.m11951a(LdlDate.m8856a(), "yyyy-MM-dd HH:mm:ss.SSSZ");
    }

    @SuppressLint({"SimpleDateFormat"})
    public static String m11951a(LdlDate c1211c, String str) {
        if (str == null) {
            str = "yyyy-MM-dd HH:mm:ss";
        }
        Calendar instance = Calendar.getInstance();
        instance.setTime(c1211c);
        return new SimpleDateFormat(str).format(instance.getTime());
    }

    @SuppressLint({"SimpleDateFormat"})
    public static String m11952a(Date date, String str) {
        if (str == null) {
            str = "yyyy-MM-dd HH:mm:ss";
        }
        Calendar instance = Calendar.getInstance();
        instance.setTime(date);
        return new SimpleDateFormat(str).format(instance.getTime());
    }

    public static String m11948a(double d) {
        int i = (int) d;
        String str = "";
        if (i < 0) {
            return str;
        }
        int i2 = i / 3600;
        i = (i % 3600) / 60;
        if (i2 > 0) {
            str = str + "" + i2 + "\u65f6";
        }
        return str + i + "\u5206";
    }

    public static String m11949a(double d, String str, String str2) {
        int i = (int) d;
        String str3 = "";
        if (i < 0) {
            return str3;
        }
        int i2 = i / 3600;
        i = (i % 3600) / 60;
        if (i2 > 0) {
            str3 = str3 + "" + i2 + str;
        }
        return str3 + i + str2;
    }

    public static String m11950a(int i) {
        try {
            StringBuilder stringBuilder = new StringBuilder();
            int i2 = i % 60;
            int i3 = (i / 60) % 60;
            String format = String.format("%02d", new Object[]{Integer.valueOf(i / 3600)});
            String format2 = String.format("%02d", new Object[]{Integer.valueOf(i3)});
            stringBuilder.append(format).append(":").append(format2).append(":").append(String.format("%02d", new Object[]{Integer.valueOf(i2)}));
            return stringBuilder.toString();
        } catch (Exception e) {
            e.printStackTrace();
            return "--:--:--";
        }
    }

    public static String m11955b(int i) {
        String str = "";
        switch (i) {
            case 1 /*1*/:
                return "\u4e00";
            case 2 /*2*/:
                return "\u4e8c";
            case 3 /*3*/:
                return "\u4e09";
            case 4 /*4*/:
                return "\u56db";
            case 5 /*5*/:
                return "\u4e94";
            case 6 /*6*/:
                return "\u516d";
            case 7 /*7*/:
                return "\u4e03";
            case 8 /*8*/:
                return "\u516b";
            case 9 /*9*/:
                return "\u4e5d";
            case 10 /*10*/:
                return "\u5341";
            case 11 /*11*/:
                return "\u5341\u4e00";
            case 12 /*12*/:
                return "\u5341\u4e8c";
            default:
                return "\u4e00";
        }
    }

    public static boolean m11953a(Date c1211c, Date c1211c2) {
        return c1211c.equals(c1211c2);
    }

    public static LdlDate m11946a(Date c1211c) {
        Calendar instance = Calendar.getInstance();
        instance.setTime(c1211c);
        instance.set(Calendar.DATE, 1);
        return LdlDate.m8859a(instance.getTime().getTime());
    }

    public static int m11954b(Date c1211c) {
        return c1211c.getDay();
    }
}
